<html><head><title>LoadXML</title></head>
<body bgcolor="#EFF1F0" link="#3A3966" vlink="#000000" alink="#000000">
<font face="Verdana, sans-serif" size="2"><p align="center"><b><font size="4">LoadXML()</font></b></p>
<p><b>Syntax</b></p><blockquote>
Result = <font color="#3A3966"><b>LoadXML</b></font>(#XML, Filename$ [, Encoding])</blockquote>

</blockquote>
<b>Description</b><br><blockquote>

Loads a XML tree from the specified file. 

</blockquote><p><b>Parameters</b></p><blockquote>
<style type="text/css">
table.parameters { border-spacing: 0px; border-style: none; border-collapse: collapse; }
table.parameters td { border-width: 1px; padding: 6px; border-style: solid; border-color: gray; vertical-align: top; font-family:Arial; font-size:10pt; }
</style>
<table width="90%" class="parameters">
<tr><td width="10%"><i>#XML</i></td>
<td width="90%"> 
A number to identify the new XML. 
<a href="../reference/purebasic_objects.html">#PB_Any</a> can be used to auto-generate this number. 

</td></tr>
<tr><td><i>Filename$</i></td>
<td> 
The filename to load the XML from. 

</td></tr>
<tr><td><i>Encoding (optional)</i></td>
<td> 
The encoding to use when loading the XML tree (this overwrites the encoding set in the XML declaration). Valid values are: 
<pre><font face="Courier New, Courier, mono"size="2">  <font color="#924B72">#PB_UTF8</font> (default)
  <font color="#924B72">#PB_Ascii</font>
  <font color="#924B72">#PB_Unicode</font>
</font></pre>
This parameter should be used when the document does not have an XML declaration, or the encoding information is 
provided outside of the XML document, for example through a mime type header in a communication protocol. 

</td></tr>
</table>
</blockquote><p><b>Return value</b></p><blockquote>

Nonzero if the file could be opened and read. Note that this does not mean that the XML contained in 
the file was valid. To check for parser errors <a href="xmlstatus.html">XMLStatus()</a> should be used. 
In case of a parsing error, all data parsed before the error is accessible in the XML tree. 
If <font color="#924B72">#PB_Any</font> was used for the #XML parameter then the generated number is returned on success. 

</blockquote><p><b>See Also</b></p><blockquote>

<a href="createxml.html">CreateXML()</a>, <a href="freexml.html">FreeXML()</a>, <a href="parsexml.html">ParseXML()</a>, <a href="catchxml.html">CatchXML()</a> 

</Blockquote><p><b>Supported OS </b><Blockquote>All</Blockquote></p><center><- <a href=isxml.html>IsXML()</a> - <a href="index.html">XML Index</a> - <a href="mainxmlnode.html">MainXMLNode()</a> -><br><br>

</body></html>